package com.zmn.oms.services.impl.quotation3;

import com.zmn.oms.model.entity.quotation3.OrderAcceptMaintainItem;
import com.zmn.oms.persistence.interfaces.quotation3.OrderAcceptMaintainItemDao;
import com.zmn.oms.services.interfaces.quotation3.OrderAcceptMaintainItemService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class OrderAcceptMaintainItemServiceImpl implements OrderAcceptMaintainItemService {

    @Resource
    private OrderAcceptMaintainItemDao orderAcceptMaintainItemDao;

    @Override
    public int countByOrderIdAndWorkId(Long orderId, Long workId) {
        return orderAcceptMaintainItemDao.countByOrderIdAndWorkId(orderId, workId);
    }

    @Override
    public List<OrderAcceptMaintainItem> listByOrderIdAndWorkId(Long orderId, Long workId) {
        return orderAcceptMaintainItemDao.listByOrderIdAndWorkId(orderId, workId);
    }

    @Override
    public List<OrderAcceptMaintainItem> listByOrderIdList(List<Long> orderIdList) {
        return orderAcceptMaintainItemDao.listByOrderIdList(orderIdList);
    }

    @Override
    public int batchInsert(List<OrderAcceptMaintainItem> orderAcceptMaintainItemList) {
        return orderAcceptMaintainItemDao.batchInsert(orderAcceptMaintainItemList);
    }

    @Override
    public int deleteByOrderId(Long orderId) {
        return orderAcceptMaintainItemDao.deleteByOrderId(orderId);
    }
}
